package com.ytf.test.third;

/**
 * @author: YTF
 * @date: 2024/9/12 17:40
 * @version: 1.0
 * @description: 指数
 */
public class Exponents {
    public static void main(String[] args) {
        // Uppercase and lowercase 'e' are the same;
        float expFloat = 1.39e-43f;
        expFloat = 1.39E-43f;
        System.out.println("expFloat:"+expFloat);
        double expDouble = 47e47d;
        expDouble = 47e47D;
        expDouble = 47e47;
        System.out.println("expDouble: "+expDouble);
        /**
         * Output:
         * expFloat:1.39E-43  相当于 1.39 × 10^(-43)
         * expDouble: 4.7E48  相当于 4.7 × 10^48
         */
        System.out.println("float 最大 "+Float.MAX_VALUE+" 最小 "+Float.MIN_VALUE);
        System.out.println("double 最大 "+Double.MAX_VALUE+" 最小 "+Double.MIN_VALUE);
    }
}
